package com.ruoyi.shop.homes.service.impl;

import com.ruoyi.mall.common.mapper.DtsHomeMapper;
import com.ruoyi.shop.homes.service.DtsHomeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class DtsHomeServiceImpl implements DtsHomeService {

    @Autowired
    private DtsHomeMapper dtsHomeMapper;

    @Override
    public Double getTodaySales() {
        return dtsHomeMapper.getTodaySales();
    }

    @Override
    public Double getYesterdaySales() {
        return dtsHomeMapper.getYesterdaySales();
    }

    @Override
    public Integer getTodayOrders() {
        return dtsHomeMapper.getTodayOrders();
    }

    @Override
    public Integer getYesterdayOrders() {
        return dtsHomeMapper.getYesterdayOrders();
    }

    @Override
    public Integer getTotalUsers() {
        return dtsHomeMapper.getTotalUsers();
    }

    @Override
    public Integer getGoodsCount() {
        return dtsHomeMapper.getGoodsCount();
    }

    @Override
    public List<Map<String, Object>> getSalesTrend(String type) {
        return dtsHomeMapper.getSalesTrend(type);
    }

    @Override
    public List<Map<String, Object>> getOrderStatus() {
        return dtsHomeMapper.getOrderStatus();
    }

    @Override
    public List<Map<String, Object>> getHotGoods() {
        return dtsHomeMapper.getHotGoods();
    }

    @Override
    public List<Map<String, Object>> getGoodsType() {
        return dtsHomeMapper.getGoodsType();
    }
}
